import Vue from 'vue'
import Meta from 'vue-meta'

import {createRouter} from '@/.lavas/router'
import {createStore} from '@/.lavas/store'
import AppComponent from './App.vue'
import Vuetify from 'vuetify'
import colors from 'vuetify/es5/util/colors'
import 'vuetify/dist/vuetify.min.css'
import 'swiper/dist/css/swiper.css'
import VueAwesomeSwiper from 'vue-awesome-swiper'

Vue.use(VueAwesomeSwiper, /* { default global options } */)
// import BaiduMap from 'vue-baidu-map'
//
// Vue.use(BaiduMap, {
//   ak: 'pWXlzLp8AADDdlqY60Yix3TSsiMSmgzA'
// })

Vue.use(Vuetify, {
  theme: {
    // primary: '#ad2624'
    primary: '#120810'
  }
})
Vue.use(Meta)

Vue.config.productionTip = false

export function createApp() {
    let router = createRouter()
    let store = createStore()
    let App = Vue.extend({
        router,
        store,
        ...AppComponent
    })
    return {App, router, store}
}

if (module.hot) {
    module.hot.accept()
}
